<template>
	<view class="info">
		<view class="message_top">
			<view class="message_top_title" :style="{top:computedTop}">个人信息</view>
			<view class="message_top_back" :style="{top:computedTop}" @click="Back">
				<image src="../../static/search/back.png" class="bfbimages"></image>
			</view>
		</view>
		
		<view class="info_box">
			<view>
				<text>头像</text>
				<view style="display: flex;align-items: center;justify-content: flex-end;">
					<view style="width: 72rpx;height: 72rpx;border-radius: 50%;overflow: hidden;background-color: green;margin-right: 10rpx;" class="flex">
						<image src="../../static/logo.png" class="bfbimages"></image>
					</view>
					<view style="width: 16rpx;height: 24rpx;text-align: center;line-height: 12rpx;"  class="flex">
						<image src="../../static/hei_right.png" class="bfbimages"></image>
					</view>
				</view>
			</view>
			
			<view>
				<text>姓名</text>
				<input type="text" style="font-size: 28rpx;color: #666666;text-align: right;font-weight: 500;" v-model="name"/>
			</view>
			
			<view>
				<text>ID</text>
				<input type="text" style="font-size: 28rpx;color: #666666;text-align: right;font-weight: 500;" v-model="id"/>
			</view>
			
			<view>
				<text>手机号</text>
				<input type="text" style="font-size: 28rpx;color: #666666;text-align: right;font-weight: 500;" v-model="phone"/>
			</view>
			
			<view>
				<text>信用积分</text>
				<input type="text" style="font-size: 28rpx;color: #666666;text-align: right;font-weight: 500;" v-model="jf"/>
			</view>
		</view>
		<view class="info_btn">确定</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				menuButtonInfo: null,
				name:'李海洋',
				id:659874123,
				phone:17629933391,
				jf:'3587'
			}
		},
		computed: {
			computedTop() {
				if (this.menuButtonInfo) {
					return `${this.menuButtonInfo.height * 2 - 6}px`;
				}
				return '0px';
			},
		},
		onLoad() {
			const info = uni.getMenuButtonBoundingClientRect();
			this.menuButtonInfo = info;
		},
		methods: {
			Back() {
				uni.navigateBack()
			}
		}
	}
</script>

<style lang="scss">
	.info {
		width: 100vw;
		height: 100vh;
		float: left;
		background-color: #F6F8FB;
	}

	.message_top {
		width: 100%;
		height: 200rpx;
		position: relative;

		.message_top_title {
			width: 100%;
			text-align: center;
			font-family: PingFang SC, PingFang SC;
			font-weight: bold;
			font-size: 36rpx;
			color: #333333;
			position: absolute;
			left: 0;
			z-index: 2;
		}

		.message_top_back {
			width: 44rpx;
			height: 44rpx;
			position: absolute;
			left: 30rpx;
			z-index: 9;
		}
	}
	
	.info_box{
		width: 650rpx;
		background: #FFFFFF;
		border-radius: 20rpx;
		margin: 20rpx auto 0;
		padding-left: 30rpx;
		padding-right: 30rpx;
	}
	
	.info_box>view{
		width: 100%;
		height: 152rpx;
		display: flex;
		align-items: center;
		justify-content: space-between;
		font-family: PingFang SC, PingFang SC;
		font-weight: bold;
		font-size: 32rpx;
		color: #333333;
	}
	
	.info_btn{
		width: 710rpx;
		height: 104rpx;
		background: linear-gradient( 270deg, #FE4624 0%, #FF8143 100%);
		border-radius: 50rpx;
		font-family: PingFang SC, PingFang SC;
		font-weight: bold;
		font-size: 36rpx;
		color: #FFFFFF;
		text-align: center;
		line-height: 104rpx;
		margin: 30rpx auto 0;
	}
</style>